package com.anyou.mall.goo.goods.service;

import java.util.List;

import com.anyou.common.core.domain.ApiResult;
import com.anyou.mall.goo.goods.domain.GooGoods;
import com.anyou.mall.goo.goods.domain.JfDraw;
import com.anyou.mall.goo.goods.dto.GoodsAddDTO;
import com.anyou.mall.goo.goods.dto.GoodsEditDTO;
import com.anyou.mall.goo.goods.dto.GoodsIntegralListDTO;
import com.anyou.mall.goo.goods.dto.IntegralDrawDTO;
import com.anyou.mall.help.domain.HelpDocument;
import com.baomidou.mybatisplus.extension.service.IService;

/**
 * 商品Service接口
 *
 * @author ruoyi
 * @date 2022-03-24
 */
public interface IGooGoodsService extends IService<GooGoods>
{
    /**
     * 查询商品
     *
     * @param goodsId 商品主键
     * @return 商品
     */
    public ApiResult<GooGoods> selectGooGoodsByGoodsId(Long goodsId);

    /**
     * 查询商品列表
     *
     * @param gooGoods 商品
     * @return 商品集合
     */
    public List<GooGoods> selectGooGoodsList(GooGoods gooGoods);

    /**
     * 新增商品
     *
     * @param goodsDTO 商品
     * @return 结果
     */
    public ApiResult insertGooGoods(GoodsAddDTO goodsDTO);

    /**
     * 修改商品
     *
     * @param goodsDTO 商品
     * @return 结果
     */
    public ApiResult updateGooGoods(GoodsEditDTO goodsDTO);

    /**
     * 批量删除商品
     *
     * @param goodsIds 需要删除的商品主键集合
     * @return 结果
     */
    public int deleteGooGoodsByGoodsIds(Long[] goodsIds);

    /**
     * 删除商品信息
     *
     * @param goodsId 商品主键
     * @return 结果
     */
    public int deleteGooGoodsByGoodsId(Long goodsId);

    /**
     * 商品上下架
     * @param goodsId
     * @param publishStatus
     * @return
     */
    ApiResult updatePublishStatus(Long goodsId, String publishStatus);

    /**
     * 商品app首页推荐
     * @param goodsId
     * @param appIndexStatus
     * @return
     */
    ApiResult updateAppIndexStatus(Long goodsId, String appIndexStatus);

    /**
     * 商品店铺首页推荐
     * @param goodsId
     * @param storeIndexStatus
     * @return
     */
    ApiResult updateStoreIndexStatus(Long goodsId, String storeIndexStatus);


    /**
     * 违规上下架
     * @param goodsId
     * @param violationStatus
     * @param remark
     * @return
     */
    ApiResult updateViolationStatus(Long goodsId, String violationStatus, String remark);

    /**
     * 分页查询积分商品列表
     * @param gooGoods
     * @return
     */
    List<GooGoods> selectGooGoodsIntegralList(GoodsIntegralListDTO gooGoods);

    /**
     * 获取积分规则
     * @return
     */
    public HelpDocument getIntegralRule();

    /**
     * 编辑积分规则
     * @param helpDocument
     * @return
     */
    public int editIntegralRule(HelpDocument helpDocument);

    /**
     * 编辑积分抽奖设置
     * @param integralDrawDTO
     * @return
     */
    public int editIntegralDraw(IntegralDrawDTO integralDrawDTO);

    /**
     * 获取积分抽奖设置
     * @return
     */
    public List<JfDraw> getIntegralDraw();

    /**
     * 获取积分抽奖规则
     * @return
     */
    public HelpDocument getIntegralDrawRule();

    /**
     * 编辑积分抽奖规则
     * @param helpDocument
     * @return
     */
    public int editIntegralDrawRule(HelpDocument helpDocument);
}
